//
// Created by ziya on 2021/11/2.
//

#include "hpp/ParkEvent.h"

ParkEvent::ParkEvent() {

    pthread_mutex_init(lock,NULL);

    pthread_cond_init(condt,NULL);
}

void ParkEvent::park() {
    pthread_mutex_lock(lock);
    pthread_cond_wait(condt,lock);
    pthread_mutex_unlock(lock);
}

